﻿
@{
    Layout = "~/Views/Shared/_Index.cshtml";
}

<form method="post" action="#">

    <div>
        <div class="topPanel">
            <div class="toolbar " style="float:right;">
                
            </div>
        </div>

    </div>

    @Html.Raw(ViewBag.WriterControlHtml)

    <script language=javascript>

         function SetCtlHeight() {
             //debugger;
             var ctl = document.getElementById("myWriterControl");
             if (ctl != null) {
                 if (ctl.getAttribute("ismobiledevice") != "true") {
                     // 对于移动设备不设置控件高度
                     //var s1 = document.documentElement.currentStyle;
                     //var s2 = document.body.currentStyle ;
                     var h = document.documentElement.clientHeight - ctl.offsetTop - 20;
                     ctl.style.height = h + "px";
                 }
                 else {
                     if (document.body.clientWidth < 400) {
                         document.getElementById("cboFileName").style.width = "100%";
                     }
                 }
             }
         }
         window.setTimeout(SetCtlHeight, 300);
         window.setInterval(SetCtlHeight, 1000);

    </script>

</form>
